A typical sliding mechanism of a server generally includes an inner rail, a middle rail, and an outer rail. The inner rail is mounted on the server, the outer rail is mounted to a support frame of the server, and the middle rail is mounted between the inner rail and the outer rail to extend the sliding distance of the sliding mechanism. Conventional sliding mechanisms can be complicated and take up a lot of space. Therefore, there is room for improvement in the art.